import { createApp } from 'vue';
import App from './App.vue';
import Antd from 'ant-design-vue';
import 'ant-design-vue/dist/reset.css';
import * as Icons from '@ant-design/icons-vue'

import { createPinia } from 'pinia'
const pinia = createPinia()

import router from "@/router";

// import '@/mock'     // 注释可以禁用mock

const app = createApp(App);
app.use(router);
app.use(pinia)
// 全局注册Antd
// 注册组件

// 全局注册图标
Object.keys(Icons).map(key => {
    app.component(key, Icons[key as keyof typeof Icons])
})

// 添加到全局
app.use(Antd).mount('#app');